GXTouchesRectanglePoint
You can use theGXTouchesRectanglePoint
function to determine if a point lies within or on the edge of a rectangle.
gxBoolean GXTouchesRectanglePoint(const gxRectangle *target, const gxPoint *test);
target
- A pointer to the rectangle to test as the container.
test
- A pointer to the point to test for inclusion.
- function result
- A Boolean value indicating whether the point touches the rectangle.
DESCRIPTION
TheGXTouchesRectanglePoint
function returnstrue
as its function result if the point specified by thetest
parameter lies within or on the edge of the rectangle specified by thetarget
parameter, and returnsfalse
otherwise.Notice that the parameters to this function are not shapes; they are pointers to a
gxPoint
or to agxRectangle
structure.ERRORS, WARNINGS, AND NOTICES
Errors parameter_is_nil SEE ALSO
For a discussion of thegxPoint
andgxRectangle
data structures, see Chapter 2, "Geometric Shapes," in this book.To determine if a rectangle touches a shape, use the
GXTouchesBoundsShape
function, described in the next section.To determine if a rectangle contains a shape, use the
GXContainsBoundsShape
function, described on page 4-101.